package be.roam.drest.service.twitter.xml;

import java.io.IOException;
import java.io.InputStream;
import java.util.Set;

import org.xml.sax.SAXException;

import be.roam.drest.service.twitter.TwitterStatus;
import be.roam.drest.xml.SaxParser;

public class TwitterXmlParser extends SaxParser {

	public static Set<TwitterStatus> parseStatus(InputStream statusResponse) throws SAXException, IOException {
        TwitterStatusHandler twitterStatusHandler = new TwitterStatusHandler();
        parse(statusResponse, twitterStatusHandler);
        return twitterStatusHandler.getStatusSet();
    }

}
